import { request } from '@/utils/request';

import type { PageData } from '@/api/model/pageModel';
import type {orderInfoModel,integralPriceModel} from '@/api/model/userModel';
import type{vipPriceModel} from '@/api/model/orderModel';
const Api = {
  IntegralPrice:'/order/price/integral', //积分定价
  VipPrice:'/order/price/vip', //积分定价
  OrderList:'/order/list',
  PayQuery:'/order/pay'
};

//订单列表
export function getOrderList(d:any)
{
  return request.get<PageData<orderInfoModel>>({
      url: Api.OrderList + '?page=' + d.page + '&pageSize=' + d.pageSize,
    });
}

//支付查询
export function payQuery(d:any)
{
  return request.get<orderInfoModel>({
    url: Api.PayQuery+'?orderNo='+d.orderno
  });
}

//查询积分定价
export function getIntegralPrice()
{
  return request.get<Array<integralPriceModel>>({
    url: Api.IntegralPrice,
  });
}
//查询VIP定价
export function getVipPrice()
{
  return request.get<Array<vipPriceModel>>({
    url: Api.VipPrice,
  });
}
